package com.torry.edss.integration.feign.tushare;

import com.alibaba.fastjson.JSONObject;
import com.torry.edss.application.configuration.FeignConfig;
import com.torry.edss.integration.feign.tushare.request.TushareFetchDailyLineRequest;
import com.torry.edss.integration.feign.tushare.request.TushareRequest;
import com.torry.boot.common.model.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.Map;

/**
 * @author torry.wang
 */
@FeignClient(name = "tuShareClient", url = "http://api.tushare.pro", configuration = FeignConfig.class)
public interface TuShareFeignClient {
    @PostMapping("/")
    Result<JSONObject> fetchData(@RequestBody TushareRequest<TushareFetchDailyLineRequest> request);
}
